package com.example.rabbitmqdemo.hellorabbitmq;

import com.rabbitmq.client.ConnectionFactory;

public class CommonUtil {


    public static ConnectionFactory getFactory() {
        ConnectionFactory factory = new ConnectionFactory();
        factory.setHost("192.168.137.2");
        factory.setPort(5672);
        // 默认
        factory.setVirtualHost("/");
        factory.setPassword("root");
        factory.setUsername("root");
        return factory;
    }

}
